<template>

    <div class="bg">

        <div class="title">
            <div>
                <i class=" iconfont icon-leftarrow"></i>
            </div>
            <div>密码登录</div>
        </div>

        <div class="log">
            <img src="../assets/image/log.png" alt="">
        </div>

        <div class="loging">

            <div>
                <input type="text" v-model="form.username" placeholder="请输入手机号">
            </div>

            <div>
                <input type="text"  v-model="form.password" placeholder="请输入密码">
                <!-- <span class="yzm">获取验证码</span> -->
            </div>

            <div class="deng" @click="login">登录</div>

            <div class="quer">

                <input type="checkbox">
                <span class="quer_word">
                    我已阅读并同意 《乐康养老用户协议》《隐私政策》
                </span>
            </div>

            <div class="wang">忘记密码</div>

        </div>


    </div>


</template>

<script>

export default {
    name: "LoGing",

    data() {
        return {
            form: {

            }
        }
    },

    methods: {



         login(){
            if (!this.form.username) {
                this.$toast.fail('请输入手机号');
                return;
            }
            if (!this.form.password) {
                this.$toast.fail('请输入密码');
                return;
            }

            // console.log(this.form);
            this.$store.dispatch('loginAsync',this.form)
            
        },
    },



}
</script>

<style lang="less">
@import url(../assets/css/LoGing/LoGing.less);
</style>